//
// Created by ZYZ on 2020/6/11.
//
#include <stdio.h>
#include "test_double_direction_linked_list.h"
#include "../../include/type_list.h"
#include "../../src/linked_list/double_direction_linked_list.h"

void test_double_direction_linked_list() {

    DuLinkList duLinkList;
    initDulLst(duLinkList);

    for (int i = 1; i <= 10; i++)
        ListInsert_DuL(duLinkList, i, i);
    ListTraverse_DuL(duLinkList);

    ElemType deletedEle;
    ListDelete_Dul(duLinkList, 2, deletedEle);
    printf("删除了元素 : %d \n", deletedEle);
    ListTraverse_DuL(duLinkList);
}